﻿namespace BlamanticUI.Components.Forms;

/// <summary>
/// Render a 'form' HTML tag with same action of <see cref="EditForm"/> component.
/// </summary>
[CssClass("form")]
public class Form : BlazorFormComponentBase<Form>, IHasUIComponent,
    IHasLoading,
    IHasSize,
    IHasEqualWidth,
    IHasInverted,
    IHasColor,
    IHasDoubling,
    IHasState
{
    /// <summary>
    /// Initializes a new instance of the <see cref="Form"/> class.
    /// </summary>
    public Form()
    {
    }
    /// <summary>
    /// Gets or sets a value indicating whether this <see cref="Form"/> is loading.
    /// </summary>
    /// <value>
    ///   <c>true</c> if loading; otherwise, <c>false</c>.
    /// </value>
    [Parameter] public bool Loading { get; set; }
    /// <summary>
    /// Gets or sets the size of all input in form.
    /// </summary>
    [Parameter] public Size? Size { get; set; }
    /// <summary>
    /// Gets or sets a value indicating whether each <see cref="Field"/> component has equal width.
    /// </summary>
    [Parameter] public bool EqualWidth { get; set; }
    /// <summary>
    /// Gets or sets a value indicating whether adapted inverted background by parent component.
    /// </summary>
    /// <value>
    ///   <c>true</c> if adapted; otherwise, <c>false</c>.
    /// </value>
    [Parameter] public bool Inverted { get; set; }
    /// <summary>
    /// Gets or sets the color of <see cref="Loading"/>.
    /// </summary>
    [Parameter] public Color? Color { get; set; }
    /// <summary>
    /// Gets or sets a value indicating whether double column of layout in responsive adapter.
    /// </summary>
    /// <value>
    ///   <c>true</c> if doubling; otherwise, <c>false</c>.
    /// </value>
    [Parameter] public bool Doubling { get; set; }
    /// <summary>
    /// Gets or sets the state of <see cref="Message"/> component.
    /// </summary>
    [Parameter] public State? State { get; set; }


}
